<!-- 更新 -->
<link rel="stylesheet" type="text/css" href="__STYLE__/common.css" />
<div class="pageContent">
    <form method="post" action="__URL__/update" class="pageForm required-validate" onsubmit="return validateCallback(this, navTabAjaxDone)" > 
        <if condition="$dataInfo|count gt 0">
        <div class="pageFormContent" layoutH="68">
			<div class="unit">
                <label>公司名称:</label>
				<input type="text" name="company_name" value="{$dataInfo['company_name']}" class="required" />
                <input type="hidden" name="id" value="{$dataInfo['id']}" />
            </div>
			<div class="unit">
                <label>公司地址:</label>
				<input type="text" name="company_address" value="{$dataInfo['company_address']}" class="required" />
            </div>
			<div class="unit">
                <label>联系电话:</label>
				<input type="text" name="tel" value="{$dataInfo['tel']}" class="required" />
            </div>
			<div class="unit">
                <label>企业邮箱:</label>
				<input type="text" name="email" value="{$dataInfo['email']}" class="required" />
            </div>
			<div class="unit">
                <label>微信二维码：</label>
                <input type="hidden" name="wechat_img" value="{$dataInfo['wechat_img']}"/>
                <input type="file" name="uploadify" id="wechat_img" class="uploadify" />
                <div class="picture oneImage">
                	<if condition="$dataInfo['wechat_img'] neq ''">
                    <img src="__ROOT__{$dataInfo['wechat_img']}" height="100" />
                    </if>
                </div>
            </div>
			<div class="unit">
                <label>企业微信二维码：</label>
                <input type="hidden" name="comp_wechat_img" value="{$dataInfo['comp_wechat_img']}"/>
                <input type="file" name="uploadify" id="comp_wechat_img" class="uploadify" />
                <div class="picture oneImage">
                	<if condition="$dataInfo['comp_wechat_img'] neq ''">
                    <img src="__ROOT__{$dataInfo['comp_wechat_img']}" height="100" />
                    </if>
                </div>
            </div>
        </div>
        <div class="formBar">
            <ul>                     <li>
                        <div class="buttonSave">
                            <div class="buttonSaveContent">
                                <button type="submit">
                            		<i class="iconfont">&#xe644;</i>保存
                                </button>
                            </div>
                        </div>
                    </li>
                    <li>
                        <div class="buttonCancel">
                            <div class="buttonCancelContent">
                                <button type="button" class="close">
                                	<i class="iconfont">&#xe640;</i>取消
                                </button>
                            </div>
                        </div>
                    </li>
            </ul>
        </div>
        </if>
    </form>
</div>
<script type="text/javascript">
    //获取分类子级信息form
    $('.unit').on("change",".cidBox",function(){
        var $this =  $(this);
        var id = $this.val();
        $.post('__URL__/getLastClass',{id : id},function(data){
            if(data !='0'){
                var str = '<select name="cid" style="width:150px;" class="combox cidBox required" ><option value="">请选择</option>';
                $.each(data,function(i,v){
                    str +='<option value="'+v.id+'">'+v.title+'</option>';
                })
                str +='</select>';
                $this.nextAll('.cidBox').remove();
                $this.after(str);
            }
        },'json');
    })
</script>